This method calculates the Balance of Power.
var BOP(openPricesArray, highPricesArray, lowPricesArray, closePricesArray, calculatedDataArray);
openPricesArray
Array object filled with open prices.
highPricesArray
Array object filled with high prices.
lowPricesArray
Array object filled with low prices.
closePricesArray
Array object filled with close prices.
calculatedDataArray
Empty Array object that will be filled with calculated data.
Returns true if calculation was completed successfully, or false otherwise.
The following example demonstrates how to use BOP method.
function calculate(beginIndex, endIndex)
{
var openPricesArray = new Array();
var highPricesArray = new Array();
var lowPricesArray = new Array();
var closePricesArray = new Array();
//populate data arrays...
...
...
var calculatedDataArray = new Array();
var rc = TechnicalAnalysis.BOP(openPricesArray, highPricesArray, lowPricesArray,
closePricesArray, calculatedDataArray);
}
Copyright © 2006-2009 ActiveTick LLC